package cn.edu.hstc.wm.service;

import java.util.ArrayList;
import java.util.List;

import cn.edu.hstc.wm.bean.Good;
import cn.edu.hstc.wm.bean.Store;

public class Test {

	/**
	 * 根据一个Store来获取其所有的goods
	 * 
	 * @param store
	 * @return
	 */
	public static List<Good> getGoodsByStore(Store store) {
		List<Good> list = new ArrayList<Good>();
		for (int i = 1; i < 20; i++) {
			Good good = new Good();
			good.setId(i);
			good.setName(store.getName() + "_菜单名_" + i);
			good.setPrice(i);
			good.setStore(store);
			good.setImageName("goods_image_" + i);
			list.add(good);
		}

		return list;
	}

}
